let rec exist x  =
 function 
   [] -> false
   |e::liste when e = x -> true
   |e::liste -> exist x liste;;

let rec add_list x l =
  match l with
     [] -> l
    |e::l when e < x -> add_list x l
    |e::l when e = x -> e::l
    |e::l -> x::e::l ;;

let rec remove_list x l =
  match l with
    [] -> l
   |e::l when e < x -> remove_list x l
   |e::l when e = x -> l 
   |e::l -> l;;

let rec map f l =
  match l with
    [] -> []
   |e::l ->f e ::map f l ;;

let rec iter f l = 
    match l with
    [] -> ()
   |e::l -> f e ; iter f l;;

let rec for_all x  = function
   [] -> true
  |e::l -> if x e 
           then for_all x l
           else false;;

let upper_case c = char_of_int (int_of_char c -32);;

let lower_case c = char_of_int (int_of_char c +32) ;;

upper_case 'c';; 

lower_case 'C';;

